package com.wtx.security.controller;

import com.wtx.security.common.ResponseResult;
import com.wtx.security.service.SysUserService;
import org.springframework.web.bind.annotation.PostMapping;
import org.springframework.web.bind.annotation.RequestMapping;
import org.springframework.web.bind.annotation.RestController;

import javax.annotation.Resource;

@RestController
@RequestMapping(value = "admin")
public class AdminController {

    @Resource
    private SysUserService sysUserService;

    @PostMapping(value = "logout")
    public ResponseResult logout(){
        sysUserService.logout();
        return new ResponseResult(200,"成功");
    }
}
